<% @microposts.each do |micropost| %>
<tr>
  <td>
    <%= micropost.jobnumber.name %>
  </td>
  <td>
    <%= micropost.category.name %>
  </td>
  <td>
    <%= micropost.subcategory.name %>
  </td>
  <td>
    <%= micropost.task %>
  </td>
  <td>
    <%= micropost.cost %>
  </td>
  <td>
    <%= micropost.date %>
  </td>
  <td>
    <%= link_to '修改', edit_micropost_path(micropost) %>
  </td>
  <td>
    <%= link_to '删除', micropost, method: :delete, data: { confirm: 'Are you sure?' } %>
  </td>
</tr>
<% end %>